package com.qianf.wisdomOrientation.mapper;

import com.qianf.wisdomOrientation.entity.Message;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.qianf.wisdomOrientation.entity.Reply;

import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author mkHeart
 * @since 2021-07-08
 */
public interface MessageMapper extends BaseMapper<Message> {
    //查询所有的消息
    List<Message> findAllMessage();

    // 根据 id查询消息的详细信息
    Message findMessageById(int id);

    // 根据 消息id查询回复的消息
    List<Message>  findMessageReply(int messageid);

    int addMessage(Message message);
}
